home *** CD-ROM | disk | FTP | other *** search
/ Spiceworld The Movie - Interactive CD-ROM / Spiceworld The Movie: Interactive CD-ROM.iso / pc / elements / spicetwo.dir / scripts_11.ls < prev    next >
Encoding:
Text File  |  1997-12-04  |  2.9 KB  |  110 lines

  1. on setBoardPos stepTime
  2.   global BOARDPOS
  3.   if stepTime = VOID then
  4.     set stepTime to 20
  5.   end if
  6.   set the member of sprite 6 to "boardPos" && string(BOARDPOS)
  7.   set the visible of sprite 2 to BOARDPOS > 8
  8.   set the visible of sprite 3 to BOARDPOS > 14
  9.   set the visible of sprite 4 to BOARDPOS > 20
  10.   set the visible of sprite 5 to BOARDPOS > 28
  11.   updateStage()
  12.   startTimer()
  13.   repeat while the timer < stepTime
  14.   end repeat
  15. end
  16.  
  17. on flashFrame
  18.   global BOARDPOS
  19.   set tempBoardPos to BOARDPOS
  20.   repeat with x = 1 to 3
  21.     set BOARDPOS to 1
  22.     setBoardPos(5)
  23.     set BOARDPOS to tempBoardPos
  24.     setBoardPos(5)
  25.   end repeat
  26. end
  27.  
  28. on playSpiceGame
  29.   global BOARDPOS, GAMESDONE
  30.   set the visible of sprite 16 to 0
  31.   set the visible of sprite 15 to 0
  32.   set the visible of sprite 13 to 0
  33.   updateStage()
  34.   set the visible of sprite 17 to 0
  35.   set the visible of sprite 14 to 1
  36.   set videoTime to the duration of member "dice Comp 1 Movie"
  37.   if random(2) = 2 then
  38.     puppetSound("bite")
  39.   else
  40.     puppetSound("shake")
  41.   end if
  42.   repeat while the movieTime of sprite 14 < videoTime
  43.     set the movieRate of sprite 14 to 1
  44.     updateStage()
  45.   end repeat
  46.   if the optionDown then
  47.     go("blow up")
  48.     exit
  49.   end if
  50.   if the shiftDown then
  51.     set diceRoll to 1
  52.   else
  53.     set diceRoll to random(5)
  54.   end if
  55.   set the member of sprite 17 to "dice" && diceRoll
  56.   set the movieTime of sprite 14 to 0
  57.   set the visible of sprite 14 to 0
  58.   set the visible of sprite 17 to 1
  59.   updateStage()
  60.   repeat with x = 1 to diceRoll
  61.     puppetSound("board move")
  62.     set BOARDPOS to BOARDPOS + 1
  63.     if BOARDPOS > 35 then
  64.       set GAMESDONE to 1
  65.       set BOARDPOS to 36
  66.       repeat with x = 1 to 10
  67.         set the visible of sprite 55 to not (the visible of sprite 55)
  68.         updateStage()
  69.         startTimer()
  70.         repeat while the timer < 20
  71.         end repeat
  72.         puppetSound("twink")
  73.       end repeat
  74.       puppetSound("girl power")
  75.       go("bomb bus")
  76.       unLoad()
  77.       next repeat
  78.     end if
  79.     setBoardPos()
  80.   end repeat
  81.   set gameList to "7 posh squares,12 baby jigsaw,15 sporty maze,22 ginger kiss,31 scary squares"
  82.   repeat with posCheck = 1 to the number of items in gameList
  83.     if BOARDPOS = value(word 1 of item posCheck of gameList) then
  84.       puppetSound("girl power")
  85.       flashFrame()
  86.       go(marker(word 2 to 3 of item posCheck of gameList))
  87.       unLoad()
  88.       exit
  89.     end if
  90.   end repeat
  91.   set QuestionList to "2,5,6,10,11,13,16,17,18,20,25,26,28,30,32,33,35"
  92.   repeat with posCheck = 1 to the number of items in QuestionList
  93.     if BOARDPOS = item posCheck of QuestionList then
  94.       flashFrame()
  95.       go("questions")
  96.       unLoad()
  97.       exit
  98.     end if
  99.   end repeat
  100.   set videoList to "4,9,19,23,27,34"
  101.   repeat with posCheck = 1 to the number of items in videoList
  102.     if BOARDPOS = item posCheck of videoList then
  103.       flashFrame()
  104.       go("video")
  105.       unLoad()
  106.       exit
  107.     end if
  108.   end repeat
  109. end
  110.